import http from '@/http'
import {
	GrounpParm,
	ZiTiParm,
	ZiTiType,
	OrderParm,
	OrderZiTipParam,
	OrderReceiverParam,
	RemarkParam
} from './MangeModel'
//获取团购管理列表
export const getListApi = (parm: GrounpParm) => {
	return http.post('/api/groupbuy/getList', parm)
}
// 自提点管理
export const getZiTiListApi = (parm: ZiTiParm) => {
	return http.post('/api/selfPriming/getList', parm)
}
//新增
export const insertApi = (parm: ZiTiType) => {
	return http.post('/api/selfPriming/insert', parm)
}
// 编辑
export const editApi = (parm: ZiTiType) => {
	return http.post('/api/selfPriming/edit', parm)
}
// 删除
export const delApi = (parm: any) => {
	return http.post('/api/selfPriming/del', parm)
}
/**
 * 获取订单管理列表
 */
export const getOrderListApi = (parm: OrderParm) => {
	return http.post('/api/orderClient/getOrderList', parm)
}
//获取订单条件
export const getSelectGroupListApi = () => {
	return http.get('/api/orderClient/getSelectGroupList')
}
//修改订单自提点
export const changeSelfPrimingApi = (parm: OrderZiTipParam) => {
	return http.post('/api/orderClient/changeSelfPriming', parm)
}
// 修改订单收件人地址
export const changeOrderReceiptApi = (parm: OrderReceiverParam) => {
	return http.post('/api/orderClient/changeOrderReceipt', parm)
}
// 修改备注
export const addOrganizerRemarktApi = (parm: RemarkParam) => {
	return http.post('/api/orderClient/addOrganizerRemark', parm)
}

//确认收货
export const confirmHarvestApi = (parm:any) => {
	return http.post('/api/orderClient/confirmHarvest', parm)
}

//退款详情（团长）
export const refundDetailApi = (parm:any) => {
	return http.post('/api/orderClient/refundDetail', parm)
}

